In many digital imaging systems, the input color image comprises several digital records, such as records composed of the red, green, and blue (R,G,B) tri-stimulus values corresponding to the color image. It is common for these records to undergo some form of a color transformation, and then to undergo some form of lossy compression prior to storage or transmission; this is followed on the receiving side by decompression, and further image processing. At the final stage of viewing or printing the image, the color components are usually transformed back to their original values, e.g., R,G,B. An example of such a system is a digital camera in which an image is captured using an image sensor covered by a color filter array (CFA). The CFA generates a subsampled RGB record, in which, depending on the configuration of the CFA used, the individual R, G, and B records may be of different sizes. The CFA image data, which represents the raw image data, is usually subjected to a color transformation. A typical color transformation provides a green record G in conjunction with two color difference records, such as (R-G) and (B-G), or (LogR-LogG) and (LogB-LogG), depending on the nature of the image capture. To conserve storage space and/or channel capacity, the transformed image is usually compressed prior to storage, using any of several well-known compression techniques, such as predictive coding or transform coding.
In the prior art, it is known to use color transforms that are suitable for images captured through a CFA, as well as to use transforms that optimize the compression performance for a given CFA pattern. Of relevance are the following patents:
U.S. Pat. No. 5,172,227 entitled "Image compression with color interpolation for a single sensor image system", by Tsai, Daly and Rabbani. PA1 U.S. Pat. No. 5,053,861 entitled "Compression method and apparatus for single-sensor color imaging systems", by Tsai, Parulski, and Rabbani. PA1 U.S. Pat. No, 5,065,229 entitled "Compression method and apparatus for single-sensor color imaging systems", by Tsai, Parulski, and Rabbani.
Each of these patents describes techniques for compressing the image signals from a single sensor color array prior to color interpolation.
The initial color transformation is typically performed independent of the subsequent compression. Consider FIG. 1, which is a block diagram of a generic digital image processing system comprising a transmitter processing section 10 and a receiver processing section 12. The transmitter processing section 10 provides an initial color transformation stage 14 for transforming input color image signals i.sub.1, i.sub.2, i.sub.3 into output c.sub.1, c.sub.2, c.sub.3 signals, followed by lossy image compression of the respective signals in a compression stage 16. The compressed bit stream is usually stored or transmitted in a signal channel 17. At the receiver processing section 12, due to the lossy nature of the compression scheme, each compressed color record is decompressed in the decompression stage 18 and reconstructed in a color transformation decoder stage 20 into a color record that is an approximation to the original color record prior to compression. The degree of approximation depends on the amount of loss that is introduced by the compression stage 16. In such systems, the initial color transformation stage 14 and the subsequent compression stage 16 are decoupled and performed in isolation.
FIG. 2 shows a common application of the generic system shown in FIG. 1. In this application, the input image is made up of three components: red (R), green (G), and blue (B). The image is transformed in the color transformation stage 14 into luminance and chrominance components, in this case, one luminance record (Y) and two color difference records (R-Y) and (B-Y). These records are compressed with loss in respective luminance and color difference compression stages 16a, 16b, 16c. At the receiver processing section 12, the original image data is approximately reconstructed by decompressing the compressed bit stream in respective luminance and color difference decompression stages 18a, 18b, 18c, followed by color decoding in the stage 20.
FIG. 3 shows a further example of the system of FIG. 1, as would typically be used in the processing section 10 of a digital electronic camera using the CFA pattern depicted in FIG. 4 (conventionally known as the Bayer pattern, and described in U.S. Pat. No. 3,971,065). The color transformation stage 14 includes a demultiplexer 22 for separating the stream of image pixels into R, G, and B records. The green (G) record, which is representative of luminance and (for the Bayer pattern) constitutes 50% of the total number of image pixels, is then interpolated in the green interpolator 24 to provide the missing green values for those pixel locations that contain a red (R) or blue (B) pixel value. Simple horizontal averaging is a suitable interpolation algorithm; other algorithms could, of course, be used. The interpolated green record, denoted by G.sub.I, is then used to form the color difference records (R-G.sub.I) and (B-G.sub.I), as depicted in FIG. 3, by summing the interpolated green record with the red and blue records in respective summing elements 26a and 26b. The original green record, along with the color difference records are compressed in stages 16a, 16b, 16c and stored in the camera in a storage module 28.
At the receiver processing section 12, this process is reversed to construct an approximation to the original image. The green record is decompressed in the luminance decompression stage 18a to provide an approximation G' of the original green record G, and then interpolated in the interpolator 24' to provide an interpolated approximation (G').sub.I of the interpolated green record G.sub.I. A particular problem is that lossy artifacts in the interpolated approximation (G').sub.I are cascaded through the red and blue records by summing the interpolated approximation (G').sub.I with the color difference approximations (R-G.sub.I)' and (B-G.sub.I)' provided by the color difference decompression stages 18b and 18c. Instead of having the green contributions cancel in the summing elements 26a', 26b', however, the lossy artifacts in the interpolated approximation (G').sub.I of the green contribution and the color difference approximations (R-G.sub.I)' and (B-G.sub.I)' are unlike, and thus do not cancel for the green contributions. This leaves the reconstructed red and blue records R', B' with lossy artifacts due to the green record.